# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=pinentry-bemenu
pkgver=0.9.0
pkgrel=0
pkgdesc="Pinentry based on bemenu"
url="https://github.com/t-8ch/pinentry-bemenu"
arch="all"
license="GPL-3.0-or-later"
makedepends="
	bemenu-dev
	libassuan-dev
	libgpg-error-dev
	meson
	popt-dev
	samurai
	"
source="https://github.com/t-8ch/pinentry-bemenu/archive/v$pkgver/pinentry-bemenu-$pkgver.tar.gz
	meson-ungit.patch
	"

build() {
	echo "$pkgver" > VERSION
	abuild-meson . output
	meson compile ${JOBS:+-j ${JOBS}} -C output
}

check() {
	meson test --no-rebuild -v -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
d69388c1734eee3bd3f97145f8c80d695f8ab18b6728cd675360bbddd55ec493f02e089187e0b88005ddb4cf628599d56ef5f055db456d5e5d3ec5760b807ae5  pinentry-bemenu-0.9.0.tar.gz
32847aaba84ebc8eb6cedb36911113ef2ce5d3ee460aea4e0f5e11e30a46ea68b3379b60622c5ef746463b0fe7d563d39f89e4b9876f021440087bc9ea941d4f  meson-ungit.patch
"
